Skip to main content

All Questions

Tagged with
1vote
1answer
206views

Best way to merge files in java [closed]

I have a task to merge set of files and each file contains words ( separated by new line ). Files contains words in sorted order. Once merged all the files, it needs to preserve the sorted order. ...
Viraj's user avatar
0votes
1answer
2kviews

Java: Is there a performance difference between variable assignment vs. inline usage?

Is there any performance detriment to assigning variables vs using them inline. I'm guessing this WOULD be worse if a method was returning primitive and I was 'boxing' it (e.g. method returning int, ...
nanotek's user avatar
1vote
1answer
197views

Feature Store Design for input data like JSON, CSV and Excel

I need a design approach for a feature store which accepts input data in the forms of CSV, EXCEL, JSON etc. The backend stack we support is Java, Spring boot and oracle DB. Note : Each file ...
crazy_code's user avatar
-6votes
1answer
160views

Are aspects of domain driven design limiting when we scale?

From what I have read about the domain driven design, an aspect of it is that there is a clear separation between domain objects and DTOs. So the application level components deal with domain objects ...
Jim's user avatar
  • 359
0votes
1answer
828views

Efficiency in Java: Object reference vs id reference

I have to represent a certain data structure, in which I have nodes that are related between them. Each node has its numeric id, and a list containing the next directly related nodes and another list ...
jacosro's user avatar
-2votes
1answer
26views

Filtering the Data and summing on one field Should I do in JAVA or write query with aggregate query with filter clause?

I have one table in which there would be millions of records. The requirement is to the records based on the condition and then total on one of the fields. Selectivity would be around approx 50. ...
Damaji kalunge's user avatar
2votes
1answer
938views

When is creating a supplier for an object less expensive than creating the object itself?

Objects contains 2 method overloads where one takes an object and the other takes a Supplier of that object: public static <T> T requireNonNull​(T obj, String message) public static <T> T ...
user1803551's user avatar
0votes
1answer
130views

Simple but frequently throwing vs reasonable but rarely throwing vs complex but never throwing [duplicate]

A lot of code that's designed to convert or parse some data of type Foo into a Bar is written with the assumption that one wouldn't intentionally pass it invalid inputs. As such, it assumes that ...
BambooleanLogic's user avatar
0votes
4answers
299views

Improvements in java based test framework to reduce execution time

Let me give a bit of background on the problem. We have a java application which has MQ integration and an Integration Test pack which is also written in java. The test pack runs all scenarios (...
phoenixSid's user avatar
0votes
0answers
346views

Best way to reduce memory consumption on persisting Java objects

Let's say I have an application that maintains relationships between objects - think of a parent-child relationship tree. The lineage of these objects are critical, so maintaining references from ...
user0000001's user avatar
-3votes
1answer
99views

Web-Application with file generation pattern

I work on a java web-application. In this application, users can generate some reporting (xls/pdf) and create some pack of multiple reporting. (using pdfbox, itext) More and more data are added in ...
Alexandre's user avatar
4votes
3answers
2kviews

How useful is JNI in android?

In java/android we can call code written in the c/c++ language for execution speed advantage. I have heard of Ahead Of Time compilation which (as far as i know) compiles the entire application to ...
pebble's user avatar
1vote
1answer
1kviews

Is new object creation necessary with BigDecimal?

Problem description: I am running performance test of calculation of PI number with primitives and with BigDecimal class. Calculation of PI with primitives is around 5-6 times faster than the same ...
DevDio's user avatar
0votes
1answer
267views

Which is better in terms of performance (bool01==bool02) vs (bool01 && bool02) [duplicate]

Which of these two is the better way of doing the same thing - public void someMethod(String s, boolean bool02){ boolean bool01 = s!=null; if(bool01==bool02){ doSomething(); } } OR public void ...
user3344591's user avatar
-3votes
1answer
339views

What are the pros and cons of using a named binary format as opposed to an unnamed one?

I'm curious to know are there any advantages or disadvantages to creating a named binary format as opposed to an unnamed one? I can only think of a increase in the required disk space. Roughly ...
Mibac's user avatar

153050per page
close